package org.example.myleet.p1470;

public class Solution {
    public int[] shuffle(int[] nums, int n) {
        int[] res = new int[nums.length];
        int i = 0, i1 = 0, i2 = nums.length / 2;
        while (i2 < nums.length) {
            res[i++] = nums[i1++];
            res[i++] = nums[i2++];
        }
        return res;
    }
}
